{% extends "./base.html" %}
{% load comment_block %}
{% block title %} {{ post.title }}{% endblock %}

{% block extra_head %}
    <link rel="stylesheet" href="https://cdn.bootcss.com/highlight.js/9.12.0/styles/googlecode.min.css">
    <script src="https://cdn.bootcss.com/highlight.js/9.12.0/highlight.min.js"></script>
    <script>hljs.initHighlightingOnLoad();</script>
{% endblock %}


{% block main %}
    {% if post %}
    <h1>{{ post.title }}Hello</h1>
    <div>
        <span>分类:<a href="{% url 'category-list' post.category_id %}">{{ post.category.name }}</a></span>
        <span>作者:<a href="#">{{ post.owner.username }}</a></span>
        <span>创建时间:{{ post.created_time }}</span>
        <span>pv/uv:{{ post.pv }}/{{ post.uv }}</span>
    </div>
    <hr/>
    <p>
        {% autoescape off %}
            {{ post.content_html }}
        {% endautoescape %}
    </p>
    {% endif %}

    {% comment_block request.path %}

{% endblock %}
